<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>账户添加页面</title>
  <link rel="stylesheet" href="../../../yl/index.css" />
  <!-- 布局样式 -->
  <link rel="stylesheet" href="../../../yl/style.css" />
  <link rel="stylesheet" href="../../../yl/mobile.css" />
  <link rel="stylesheet" href="../../../yl/easyui.css" />
  <link rel="stylesheet" href="../../../yl/icon.css" />
</head>

<body>
  <!-- <div id="app"> -->
  <div class="easyui-navpanel" id="app" v-cloak>
    <header>
      <div class="m-toolbar">
        <div class="m-title">参与成员共{{Data.length}}人</div>
      </div>
    </header>
    <div class="easyui-navpanel panel-body panel-body-nobottom panel-body-noborder" style="height: 3000px">
      <div class="yl-main">
        <el-table border tooltip-effect="dark" :data="Data" @selection-change="handleSelectionChange"
          style="height: 100%; margin-top: 20px;" ref="multipleTable">
          <el-table-column fixed="left" :selectable="selectable" type="selection" width="40"></el-table-column>
          <el-table-column width="50" align="center" type="index" label="#"></el-table-column>
          <el-table-column min-width="180" align="center" prop="Activity_Name" label="活动名称"></el-table-column>
          <el-table-column min-width="180" align="center" prop="Personal_Name" label="报名人员"></el-table-column>
          <el-table-column min-width="180" align="center" prop="Activity_Datetime" label="活动时间"></el-table-column>
          <el-table-column min-width="180" align="center" prop="Activity_Points" label="参与积分(村民积分)"></el-table-column>
          <el-table-column min-width="180" align="center" prop="Check_In_Datetime" label="签到时间"></el-table-column>
          <el-table-column width="140" align="center" prop="Picture_URL" label="打卡照片">
            <template v-slot="{row}">
              <el-image v-if="row.Picture_URL" style="width: 100px; height: 100px" :src="photo + row.Picture_URL" fit="contain"></el-image>
              <div v-else>
                暂未上传打卡照片
              </div>
            </template>
          </el-table-column>
          <el-table-column width="220" align="center" fixed="right" label="操作">
            <template v-slot="{row}">
              <div style="display: flex; align-items: center; justify-content: space-around;">
                <el-button :disabled="row.Check_In_Datetime != ''" size="small"
                  :type="row.Check_In_Datetime != ''?'info':'success'" style="margin-right: 10px;"
                  @click="handle(row)">手动签到</el-button>
                <el-dropdown v-if="row.isPoints == '0'" trigger="click">
                  <el-button size="small" type="warning">
                    是否发放积分<el-icon class="el-icon--right"><arrow-down /></el-icon>
                  </el-button>
                  <template #dropdown>
                    <el-dropdown-menu>
                      <el-dropdown-item @click="handleBatchPoints('1',row)">
                        发放积分
                      </el-dropdown-item>
                      <el-dropdown-item @click="handleBatchPoints('2',row)">
                        取消发放
                      </el-dropdown-item>
                    </el-dropdown-menu>
                  </template>
                </el-dropdown>
              </div>
            </template>
          </el-table-column>
        </el-table>
      </div>
    </div>
    <el-dialog v-model="showDialog" width="550" class="custom-dialog">
      <template #header>
        <div class="dialog-header">
          <span>签到时间</span>
        </div>
      </template>
      <div class="dialog-content">
        <el-form :model="form" ref="form" :inline-message="true" style="width: 100%" :destroy-on-close="true"
        :close-on-click-modal="false">
          <el-descriptions :column="1" size="large" border>
            <el-descriptions-item>
              <template #label>
                <div class="cell-item">签到时间</div>
              </template>
              <el-form-item prop="Check_In_Datetime"
                :rules="[{ required: true, message:'请选择签到时间', trigger: 'change' }]">
                <el-date-picker v-model="form.Check_In_Datetime" type="datetime" placeholder="请选择签到时间"
                  class="borderless-input" style="width: 100%;" format="YYYY-MM-DD HH:mm:ss"
                  value-format="YYYY-MM-DD HH:mm:ss" size="large" />
              </el-form-item>
            </el-descriptions-item>
            <el-descriptions-item>
              <template #label>
                <div class="cell-item">上传图片</div>
              </template>
              <el-form-item prop="Picture_URL">
                <yl-upload v-model="form.Picture_URL"></yl-upload>
              </el-form-item>
            </el-descriptions-item>
          </el-descriptions>
        </el-form>
      </div>
      <template #footer>
        <div class="dialog-footer">
          <el-button @click="showDialog = false" class="cancel-btn">取消</el-button>
          <el-button type="primary" @click="handleSubmit" class="confirm-btn">保存</el-button>
        </div>
      </template>
    </el-dialog>
    <el-dialog v-model="showDialog1" width="800" class="custom-dialog">
      <template #header>
        <div class="dialog-header">
          <span> 上传附件</span>
        </div>
      </template>
      <div class="dialog-content">
        <el-form :model="form" ref="form" :inline-message="true" style="width: 100%">
          <yl-upload ref="ylUpload" drag @success="success" @remove="remove" :limit="99" :file="fileList"></yl-upload>
        </el-form>
      </div>
      <template #footer>
        <div class="dialog-footer">
          <el-button @click="showDialog1 = false" class="cancel-btn">取消</el-button>
          <el-button type="primary" @click="submitBatchPoints('1')" class="confirm-btn">确认</el-button>
        </div>
      </template>
    </el-dialog>
    <footer class="botton-ann">
      <el-button @click="batchSign">批量签到</el-button>
      <el-button @click="batchPoints" :type="isPoints?'danger':'success'">{{isPoints?'取消批量发放':'批量发放积分'}}</el-button>
      <template v-if="isPoints">
        <el-button @click="handleBatchPoints('1')" type="success">发放积分</el-button>
        <el-button @click="submitBatchPoints('2')" type="danger">拒绝发放</el-button>
      </template>
      <el-button @click="goBack">返回</el-button>
    </footer>
  </div>
</body>
<script src="../../../utils/utils.js"></script>
<script src="../../../config/config.js"></script>
<script src="../../../utils/compressor.js"></script>
<script src="../../../utils/mixins.js"></script>
<script src="../../../yl/vue.js"></script>
<script src="../../../yl/index.js"></script>
<script src="../../../yl/zh-cn.mjs"></script>
<script src="../../../yl/index.iife.min.js"></script>
<script src="../../../yl/jquery.min.js"></script>
<script src="../../../utils/jquery.cookie.js"></script>
<script src="../../../yl/jquery.easyui.min.js"></script>
<script src="../../../yl/jquery.easyui.mobile.js"></script>
<script src="../../../yl/moment.min.js"></script>
<script src="../../../api/request.js"></script>
<script src="./js/show.js"></script>

</html>